// d:\W\wwx\bytedance\FIGHTING\pages\EngName\condition\index.js
Page({
    data: {
        backImg: '../../../images/EngName/bg.jpg',
        typeList: ['运动', '自信', '友善', '霸气', '美丽', '单纯', '乐观', '坚持', '勇敢'],
        pyList: [
            { value :'A', checked :false},
            { value :'B', checked :false},
            { value :'C', checked :false},
            { value :'D', checked :false},
            { value :'E', checked :false},
            { value :'F', checked :false},
            { value :'G', checked :false},
            { value :'H', checked :false},
            { value :'I', checked :false},
            { value :'J', checked :false},
            { value :'K', checked :false},
            { value :'L', checked :false},
            { value :'M', checked :false},
            { value :'N', checked :false},
            { value :'O', checked :false},
            { value :'P', checked :false},
            { value :'Q', checked :false},
            { value :'R', checked :false},
            { value :'S', checked :false},
            { value :'T', checked :false},
            { value :'U', checked :false},
            { value :'V', checked :false},
            { value :'W', checked :false},
            { value :'X', checked :false},
            { value :'Y', checked :false},
            { value :'Z', checked :false}]
    },
    onLoad: function(options) {

    },
    //选中、取消时设置拼音样式
    pyChecked: function(event) {
        var currentIndex = event.currentTarget.dataset.index;
        var pyObj = this.data.pyList[currentIndex];
        var isChecked = (!pyObj.checked?true:false);
        this.data.pyList[currentIndex].checked = isChecked;
        this.setData({
            pyList:this.data.pyList
        });
    }
})